wordpress query a post by id

31

// Retrieve the ID of the current item in the WordPress Loop.
get_the_ID()
    $args=array(
    'posts_per_page' => 50, 
    'post_type' => 'my_custom_type'
    'cat' => $cat_id,
);
$wp_query = new WP_Query( $args );

Comments

Submit
0 Comments